package com.mingtu.dzpatrol.adapter;

import android.view.ViewGroup;

import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;


import com.mingtu.dzpatrol.viewpager.LazyViewPager.LazyFragmentPagerAdapter;

import java.util.List;

/**
 * @ClassName :
 * @Author : wkk
 * @Date : 2020/6/19 15:20:17
 * @Email : 1281573890@qq.com
 * @Eescription :
 */
public class TabbarAdapter extends LazyFragmentPagerAdapter {
    private List<Fragment> list;

    public TabbarAdapter(FragmentManager fm, List<Fragment> list) {
        super(fm);
        this.list = list;
    }


    @Override
    public int getCount() {
        return list.size();
    }


    @Override
    protected Fragment getItem(ViewGroup container, int position) {
        return list.get(position);
    }
}
